home *** CD-ROM | disk | FTP | other *** search
/ .net 2002 March / DotNetMagazine-Issue107-Coverdisc-NET107-02-03-PCMac.bin / pc / PC Software / free_browsing / DavesQckSearchDbar3-14 / dqsd.exe / searches / fm.xml < prev    next >
Text File  |  2002-08-30  |  2KB  |  70 lines

  1. <search function="fm">
  2.   <name>Freshmeat.net</name>
  3.   <description>
  4.     Search open source projects on Freshmeat.net.<br/>
  5.     <div class="helpboxDescLabels">Switches:</div>
  6.       <table class="helpboxDescTable">
  7.           <tr><td>/projects</td><td> - </td><td>Projects</td></tr>
  8.           <tr><td>/articles</td><td> - </td><td>Articles</td></tr>
  9.           <tr><td>/comments</td><td> - </td><td>Comments</td></tr>
  10.       </table>
  11.     <div class="helpboxDescLabels">Examples:</div>
  12.     <table class="helpboxDescTable">
  13.           <tr><td>fm php graph</td></tr>
  14.       </table>
  15.   </description>
  16.   <category>Computers</category>
  17.   <link>http://www.freshmeat.net/</link>
  18.   <contributor>Brent Beardsley</contributor>
  19.   
  20.   <form name="fmsearch"
  21.         action="http://www.freshmeat.net/search/"
  22.         method="get">
  23.     <input type="hidden" name="q"/>
  24.     <input type="hidden" name="section"/>
  25.   </form>
  26.   
  27.   <script><![CDATA[
  28.     function fm(q)
  29.     {
  30.       if( nullArgs("fm", q) )
  31.         return false;
  32.  
  33.       var args = parseArgs(q, "projects, articles, comments");
  34.       if( q == "" )
  35.         openSearchWindow("http://www.freshmeat.net/");
  36.       else if( args.switches.length == 1 )
  37.       {
  38.         switch( args.switches[0].name )
  39.         {
  40.           case "projects":
  41.             document.fmsearch.section.value = "projects"; break;
  42.           case "comments":
  43.             document.fmsearch.section.value = "comments"; break;
  44.           case "articles":
  45.             document.fmsearch.section.value = "articles"; break;
  46.           default:
  47.             document.fmsearch.section.value = args.switches[0].name; break;
  48.         }
  49.         document.fmsearch.q.value = args.q;
  50.         submitForm(fmsearch);
  51.       }
  52.       else if( args.switches.length > 1 )
  53.         nullArgs("fm","?");
  54.       else
  55.       {
  56.         document.fmsearch.section.value = "projects";
  57.         document.fmsearch["q"].value = args.q;
  58.         submitForm(fmsearch);
  59.       }
  60.     }
  61.   ]]></script>
  62.  
  63.   <copyright>
  64.     Copyright (c) 2002 David Bau
  65.     Distributed under the terms of the
  66.     GNU Public License, Version 2 (http://www.gnu.org/copyleft/gpl.txt)
  67.   </copyright>
  68. </search>
  69.  
  70.